Integrand size = 31, antiderivative size = 209 \[ \int \cos ^2(c+d x) (a+b \sec (c+d x))^4 (A+B \sec (c+d x)) \, dx=\frac {1}{2} a^2 \left (a^2 A+12 A b^2+8 a b B\right ) x+\frac {b^2 \left (8 a A b+12 a^2 B+b^2 B\right ) \text {arctanh}(\sin (c+d x))}{2 d}+\frac {a (5 A b+2 a B) (a+b \sec (c+d x))^2 \sin (c+d x)}{2 d}+\frac {a A \cos (c+d x) (a+b \sec (c+d x))^3 \sin (c+d x)}{2 d}-\frac {b \left (13 a^2 A b-2 A b^3+4 a^3 B-8 a b^2 B\right ) \tan (c+d x)}{2 d}-\frac {b^2 \left (6 a A b+2 a^2 B-b^2 B\right ) \sec (c+d x) \tan (c+d x)}{2 d} \]
[Out]
Time = 0.48 (sec) , antiderivative size = 209, normalized size of antiderivative = 1.00, number of steps used = 7, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.194, Rules used = {4110, 4179, 4133, 3855, 3852, 8} \[ \int \cos ^2(c+d x) (a+b \sec (c+d x))^4 (A+B \sec (c+d x)) \, dx=\frac {b^2 \left (12 a^2 B+8 a A b+b^2 B\right ) \text {arctanh}(\sin (c+d x))}{2 d}-\frac {b^2 \left (2 a^2 B+6 a A b-b^2 B\right ) \tan (c+d x) \sec (c+d x)}{2 d}+\frac {1}{2} a^2 x \left (a^2 A+8 a b B+12 A b^2\right )-\frac {b \left (4 a^3 B+13 a^2 A b-8 a b^2 B-2 A b^3\right ) \tan (c+d x)}{2 d}+\frac {a (2 a B+5 A b) \sin (c+d x) (a+b \sec (c+d x))^2}{2 d}+\frac {a A \sin (c+d x) \cos (c+d x) (a+b \sec (c+d x))^3}{2 d} \]
[In]
[Out]
Rule 8
Rule 3852
Rule 3855
Rule 4110
Rule 4133
Rule 4179
Rubi steps \begin{align*} \text {integral}& = \frac {a A \cos (c+d x) (a+b \sec (c+d x))^3 \sin (c+d x)}{2 d}-\frac {1}{2} \int \cos (c+d x) (a+b \sec (c+d x))^2 \left (-a (5 A b+2 a B)-\left (a^2 A+2 A b^2+4 a b B\right ) \sec (c+d x)+2 b (a A-b B) \sec ^2(c+d x)\right ) \, dx \\ & = \frac {a (5 A b+2 a B) (a+b \sec (c+d x))^2 \sin (c+d x)}{2 d}+\frac {a A \cos (c+d x) (a+b \sec (c+d x))^3 \sin (c+d x)}{2 d}-\frac {1}{2} \int (a+b \sec (c+d x)) \left (-a \left (a^2 A+12 A b^2+8 a b B\right )+b \left (a^2 A-2 A b^2-6 a b B\right ) \sec (c+d x)+2 b \left (6 a A b+2 a^2 B-b^2 B\right ) \sec ^2(c+d x)\right ) \, dx \\ & = \frac {a (5 A b+2 a B) (a+b \sec (c+d x))^2 \sin (c+d x)}{2 d}+\frac {a A \cos (c+d x) (a+b \sec (c+d x))^3 \sin (c+d x)}{2 d}-\frac {b^2 \left (6 a A b+2 a^2 B-b^2 B\right ) \sec (c+d x) \tan (c+d x)}{2 d}-\frac {1}{4} \int \left (-2 a^2 \left (a^2 A+12 A b^2+8 a b B\right )-2 b^2 \left (8 a A b+12 a^2 B+b^2 B\right ) \sec (c+d x)+2 b \left (13 a^2 A b-2 A b^3+4 a^3 B-8 a b^2 B\right ) \sec ^2(c+d x)\right ) \, dx \\ & = \frac {1}{2} a^2 \left (a^2 A+12 A b^2+8 a b B\right ) x+\frac {a (5 A b+2 a B) (a+b \sec (c+d x))^2 \sin (c+d x)}{2 d}+\frac {a A \cos (c+d x) (a+b \sec (c+d x))^3 \sin (c+d x)}{2 d}-\frac {b^2 \left (6 a A b+2 a^2 B-b^2 B\right ) \sec (c+d x) \tan (c+d x)}{2 d}+\frac {1}{2} \left (b^2 \left (8 a A b+12 a^2 B+b^2 B\right )\right ) \int \sec (c+d x) \, dx-\frac {1}{2} \left (b \left (13 a^2 A b-2 A b^3+4 a^3 B-8 a b^2 B\right )\right ) \int \sec ^2(c+d x) \, dx \\ & = \frac {1}{2} a^2 \left (a^2 A+12 A b^2+8 a b B\right ) x+\frac {b^2 \left (8 a A b+12 a^2 B+b^2 B\right ) \text {arctanh}(\sin (c+d x))}{2 d}+\frac {a (5 A b+2 a B) (a+b \sec (c+d x))^2 \sin (c+d x)}{2 d}+\frac {a A \cos (c+d x) (a+b \sec (c+d x))^3 \sin (c+d x)}{2 d}-\frac {b^2 \left (6 a A b+2 a^2 B-b^2 B\right ) \sec (c+d x) \tan (c+d x)}{2 d}+\frac {\left (b \left (13 a^2 A b-2 A b^3+4 a^3 B-8 a b^2 B\right )\right ) \text {Subst}(\int 1 \, dx,x,-\tan (c+d x))}{2 d} \\ & = \frac {1}{2} a^2 \left (a^2 A+12 A b^2+8 a b B\right ) x+\frac {b^2 \left (8 a A b+12 a^2 B+b^2 B\right ) \text {arctanh}(\sin (c+d x))}{2 d}+\frac {a (5 A b+2 a B) (a+b \sec (c+d x))^2 \sin (c+d x)}{2 d}+\frac {a A \cos (c+d x) (a+b \sec (c+d x))^3 \sin (c+d x)}{2 d}-\frac {b \left (13 a^2 A b-2 A b^3+4 a^3 B-8 a b^2 B\right ) \tan (c+d x)}{2 d}-\frac {b^2 \left (6 a A b+2 a^2 B-b^2 B\right ) \sec (c+d x) \tan (c+d x)}{2 d} \\ \end{align*}
Time = 3.63 (sec) , antiderivative size = 310, normalized size of antiderivative = 1.48 \[ \int \cos ^2(c+d x) (a+b \sec (c+d x))^4 (A+B \sec (c+d x)) \, dx=\frac {2 a^2 \left (a^2 A+12 A b^2+8 a b B\right ) (c+d x)-2 b^2 \left (8 a A b+12 a^2 B+b^2 B\right ) \log \left (\cos \left (\frac {1}{2} (c+d x)\right )-\sin \left (\frac {1}{2} (c+d x)\right )\right )+2 b^2 \left (8 a A b+12 a^2 B+b^2 B\right ) \log \left (\cos \left (\frac {1}{2} (c+d x)\right )+\sin \left (\frac {1}{2} (c+d x)\right )\right )+\frac {b^4 B}{\left (\cos \left (\frac {1}{2} (c+d x)\right )-\sin \left (\frac {1}{2} (c+d x)\right )\right )^2}+\frac {4 b^3 (A b+4 a B) \sin \left (\frac {1}{2} (c+d x)\right )}{\cos \left (\frac {1}{2} (c+d x)\right )-\sin \left (\frac {1}{2} (c+d x)\right )}-\frac {b^4 B}{\left (\cos \left (\frac {1}{2} (c+d x)\right )+\sin \left (\frac {1}{2} (c+d x)\right )\right )^2}+\frac {4 b^3 (A b+4 a B) \sin \left (\frac {1}{2} (c+d x)\right )}{\cos \left (\frac {1}{2} (c+d x)\right )+\sin \left (\frac {1}{2} (c+d x)\right )}+4 a^3 (4 A b+a B) \sin (c+d x)+a^4 A \sin (2 (c+d x))}{4 d} \]
[In]
[Out]
Time = 2.75 (sec) , antiderivative size = 187, normalized size of antiderivative = 0.89
method | result | size |
derivativedivides | \(\frac {a^{4} A \left (\frac {\cos \left (d x +c \right ) \sin \left (d x +c \right )}{2}+\frac {d x}{2}+\frac {c}{2}\right )+B \,a^{4} \sin \left (d x +c \right )+4 A \,a^{3} b \sin \left (d x +c \right )+4 B \,a^{3} b \left (d x +c \right )+6 A \,a^{2} b^{2} \left (d x +c \right )+6 B \,a^{2} b^{2} \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )+4 A a \,b^{3} \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )+4 B \tan \left (d x +c \right ) a \,b^{3}+A \tan \left (d x +c \right ) b^{4}+B \,b^{4} \left (\frac {\sec \left (d x +c \right ) \tan \left (d x +c \right )}{2}+\frac {\ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{2}\right )}{d}\) | \(187\) |
default | \(\frac {a^{4} A \left (\frac {\cos \left (d x +c \right ) \sin \left (d x +c \right )}{2}+\frac {d x}{2}+\frac {c}{2}\right )+B \,a^{4} \sin \left (d x +c \right )+4 A \,a^{3} b \sin \left (d x +c \right )+4 B \,a^{3} b \left (d x +c \right )+6 A \,a^{2} b^{2} \left (d x +c \right )+6 B \,a^{2} b^{2} \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )+4 A a \,b^{3} \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )+4 B \tan \left (d x +c \right ) a \,b^{3}+A \tan \left (d x +c \right ) b^{4}+B \,b^{4} \left (\frac {\sec \left (d x +c \right ) \tan \left (d x +c \right )}{2}+\frac {\ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{2}\right )}{d}\) | \(187\) |
parallelrisch | \(\frac {-32 b^{2} \left (1+\cos \left (2 d x +2 c \right )\right ) \left (A a b +\frac {3}{2} B \,a^{2}+\frac {1}{8} b^{2} B \right ) \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )+32 b^{2} \left (1+\cos \left (2 d x +2 c \right )\right ) \left (A a b +\frac {3}{2} B \,a^{2}+\frac {1}{8} b^{2} B \right ) \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )+4 a^{2} d x \left (A \,a^{2}+12 A \,b^{2}+8 B a b \right ) \cos \left (2 d x +2 c \right )+2 \left (a^{4} A +4 A \,b^{4}+16 B a \,b^{3}\right ) \sin \left (2 d x +2 c \right )+4 \left (4 A \,a^{3} b +B \,a^{4}\right ) \sin \left (3 d x +3 c \right )+a^{4} A \sin \left (4 d x +4 c \right )+4 \left (4 A \,a^{3} b +B \,a^{4}+2 B \,b^{4}\right ) \sin \left (d x +c \right )+4 a^{2} d x \left (A \,a^{2}+12 A \,b^{2}+8 B a b \right )}{8 d \left (1+\cos \left (2 d x +2 c \right )\right )}\) | \(262\) |
risch | \(\frac {a^{4} A x}{2}+6 A \,a^{2} b^{2} x +4 B \,a^{3} b x -\frac {i b^{3} \left (B b \,{\mathrm e}^{3 i \left (d x +c \right )}-2 A b \,{\mathrm e}^{2 i \left (d x +c \right )}-8 B a \,{\mathrm e}^{2 i \left (d x +c \right )}-B b \,{\mathrm e}^{i \left (d x +c \right )}-2 A b -8 B a \right )}{d \left ({\mathrm e}^{2 i \left (d x +c \right )}+1\right )^{2}}+\frac {2 i {\mathrm e}^{-i \left (d x +c \right )} A \,a^{3} b}{d}+\frac {i a^{4} A \,{\mathrm e}^{-2 i \left (d x +c \right )}}{8 d}-\frac {i a^{4} A \,{\mathrm e}^{2 i \left (d x +c \right )}}{8 d}-\frac {2 i {\mathrm e}^{i \left (d x +c \right )} A \,a^{3} b}{d}+\frac {i {\mathrm e}^{-i \left (d x +c \right )} B \,a^{4}}{2 d}-\frac {i {\mathrm e}^{i \left (d x +c \right )} B \,a^{4}}{2 d}-\frac {4 \ln \left ({\mathrm e}^{i \left (d x +c \right )}-i\right ) A a \,b^{3}}{d}-\frac {6 \ln \left ({\mathrm e}^{i \left (d x +c \right )}-i\right ) B \,a^{2} b^{2}}{d}-\frac {\ln \left ({\mathrm e}^{i \left (d x +c \right )}-i\right ) B \,b^{4}}{2 d}+\frac {4 \ln \left ({\mathrm e}^{i \left (d x +c \right )}+i\right ) A a \,b^{3}}{d}+\frac {6 \ln \left ({\mathrm e}^{i \left (d x +c \right )}+i\right ) B \,a^{2} b^{2}}{d}+\frac {\ln \left ({\mathrm e}^{i \left (d x +c \right )}+i\right ) B \,b^{4}}{2 d}\) | \(365\) |
norman | \(\frac {\left (\frac {1}{2} a^{4} A +6 A \,a^{2} b^{2}+4 B \,a^{3} b \right ) x +\left (-\frac {1}{2} a^{4} A -6 A \,a^{2} b^{2}-4 B \,a^{3} b \right ) x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{4}+\left (-\frac {1}{2} a^{4} A -6 A \,a^{2} b^{2}-4 B \,a^{3} b \right ) x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{8}+\left (\frac {1}{2} a^{4} A +6 A \,a^{2} b^{2}+4 B \,a^{3} b \right ) x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{12}+\left (-a^{4} A -12 A \,a^{2} b^{2}-8 B \,a^{3} b \right ) x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}+\left (-a^{4} A -12 A \,a^{2} b^{2}-8 B \,a^{3} b \right ) x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{10}+\left (2 a^{4} A +24 A \,a^{2} b^{2}+16 B \,a^{3} b \right ) x \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{6}+\frac {\left (a^{4} A +8 A \,a^{3} b +2 A \,b^{4}+2 B \,a^{4}+8 B a \,b^{3}+B \,b^{4}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{d}+\frac {\left (5 a^{4} A -24 A \,a^{3} b +2 A \,b^{4}-6 B \,a^{4}+8 B a \,b^{3}+B \,b^{4}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{9}}{d}-\frac {\left (a^{4} A -8 A \,a^{3} b +2 A \,b^{4}-2 B \,a^{4}+8 B a \,b^{3}-B \,b^{4}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{11}}{d}-\frac {2 \left (5 a^{4} A -8 A \,a^{3} b -2 A \,b^{4}-2 B \,a^{4}-8 B a \,b^{3}+B \,b^{4}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{7}}{d}+\frac {2 \left (5 a^{4} A +8 A \,a^{3} b -2 A \,b^{4}+2 B \,a^{4}-8 B a \,b^{3}-B \,b^{4}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{5}}{d}-\frac {\left (5 a^{4} A +24 A \,a^{3} b +2 A \,b^{4}+6 B \,a^{4}+8 B a \,b^{3}-B \,b^{4}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{3}}{d}}{\left (1+\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}\right )^{2} \left (-1+\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}\right )^{4}}-\frac {b^{2} \left (8 A a b +12 B \,a^{2}+b^{2} B \right ) \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}{2 d}+\frac {b^{2} \left (8 A a b +12 B \,a^{2}+b^{2} B \right ) \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )}{2 d}\) | \(670\) |
[In]
[Out]
none
Time = 0.31 (sec) , antiderivative size = 202, normalized size of antiderivative = 0.97 \[ \int \cos ^2(c+d x) (a+b \sec (c+d x))^4 (A+B \sec (c+d x)) \, dx=\frac {2 \, {\left (A a^{4} + 8 \, B a^{3} b + 12 \, A a^{2} b^{2}\right )} d x \cos \left (d x + c\right )^{2} + {\left (12 \, B a^{2} b^{2} + 8 \, A a b^{3} + B b^{4}\right )} \cos \left (d x + c\right )^{2} \log \left (\sin \left (d x + c\right ) + 1\right ) - {\left (12 \, B a^{2} b^{2} + 8 \, A a b^{3} + B b^{4}\right )} \cos \left (d x + c\right )^{2} \log \left (-\sin \left (d x + c\right ) + 1\right ) + 2 \, {\left (A a^{4} \cos \left (d x + c\right )^{3} + B b^{4} + 2 \, {\left (B a^{4} + 4 \, A a^{3} b\right )} \cos \left (d x + c\right )^{2} + 2 \, {\left (4 \, B a b^{3} + A b^{4}\right )} \cos \left (d x + c\right )\right )} \sin \left (d x + c\right )}{4 \, d \cos \left (d x + c\right )^{2}} \]
[In]
[Out]
\[ \int \cos ^2(c+d x) (a+b \sec (c+d x))^4 (A+B \sec (c+d x)) \, dx=\int \left (A + B \sec {\left (c + d x \right )}\right ) \left (a + b \sec {\left (c + d x \right )}\right )^{4} \cos ^{2}{\left (c + d x \right )}\, dx \]
[In]
[Out]
none
Time = 0.22 (sec) , antiderivative size = 209, normalized size of antiderivative = 1.00 \[ \int \cos ^2(c+d x) (a+b \sec (c+d x))^4 (A+B \sec (c+d x)) \, dx=\frac {{\left (2 \, d x + 2 \, c + \sin \left (2 \, d x + 2 \, c\right )\right )} A a^{4} + 16 \, {\left (d x + c\right )} B a^{3} b + 24 \, {\left (d x + c\right )} A a^{2} b^{2} - B b^{4} {\left (\frac {2 \, \sin \left (d x + c\right )}{\sin \left (d x + c\right )^{2} - 1} - \log \left (\sin \left (d x + c\right ) + 1\right ) + \log \left (\sin \left (d x + c\right ) - 1\right )\right )} + 12 \, B a^{2} b^{2} {\left (\log \left (\sin \left (d x + c\right ) + 1\right ) - \log \left (\sin \left (d x + c\right ) - 1\right )\right )} + 8 \, A a b^{3} {\left (\log \left (\sin \left (d x + c\right ) + 1\right ) - \log \left (\sin \left (d x + c\right ) - 1\right )\right )} + 4 \, B a^{4} \sin \left (d x + c\right ) + 16 \, A a^{3} b \sin \left (d x + c\right ) + 16 \, B a b^{3} \tan \left (d x + c\right ) + 4 \, A b^{4} \tan \left (d x + c\right )}{4 \, d} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 528 vs. \(2 (197) = 394\).
Time = 0.36 (sec) , antiderivative size = 528, normalized size of antiderivative = 2.53 \[ \int \cos ^2(c+d x) (a+b \sec (c+d x))^4 (A+B \sec (c+d x)) \, dx=\frac {{\left (A a^{4} + 8 \, B a^{3} b + 12 \, A a^{2} b^{2}\right )} {\left (d x + c\right )} + {\left (12 \, B a^{2} b^{2} + 8 \, A a b^{3} + B b^{4}\right )} \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 1 \right |}\right ) - {\left (12 \, B a^{2} b^{2} + 8 \, A a b^{3} + B b^{4}\right )} \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 1 \right |}\right ) - \frac {2 \, {\left (A a^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{7} - 2 \, B a^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{7} - 8 \, A a^{3} b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{7} + 8 \, B a b^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{7} + 2 \, A b^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{7} - B b^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{7} - 3 \, A a^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} + 2 \, B a^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} + 8 \, A a^{3} b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} + 8 \, B a b^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} + 2 \, A b^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} - 3 \, B b^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} + 3 \, A a^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 2 \, B a^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 8 \, A a^{3} b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - 8 \, B a b^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - 2 \, A b^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - 3 \, B b^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - A a^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 2 \, B a^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 8 \, A a^{3} b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 8 \, B a b^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 2 \, A b^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - B b^{4} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )}}{{\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{4} - 1\right )}^{2}}}{2 \, d} \]
[In]
[Out]
Time = 16.76 (sec) , antiderivative size = 330, normalized size of antiderivative = 1.58 \[ \int \cos ^2(c+d x) (a+b \sec (c+d x))^4 (A+B \sec (c+d x)) \, dx=\frac {2\,\left (\frac {A\,a^4\,\mathrm {atan}\left (\frac {\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}\right )}{2}+\frac {B\,b^4\,\mathrm {atanh}\left (\frac {\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}\right )}{2}+4\,A\,a\,b^3\,\mathrm {atanh}\left (\frac {\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}\right )+4\,B\,a^3\,b\,\mathrm {atan}\left (\frac {\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}\right )+6\,A\,a^2\,b^2\,\mathrm {atan}\left (\frac {\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}\right )+6\,B\,a^2\,b^2\,\mathrm {atanh}\left (\frac {\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}\right )\right )}{d}+\frac {\frac {A\,a^4\,\sin \left (2\,c+2\,d\,x\right )}{8}+\frac {A\,a^4\,\sin \left (4\,c+4\,d\,x\right )}{16}+\frac {A\,b^4\,\sin \left (2\,c+2\,d\,x\right )}{2}+\frac {B\,a^4\,\sin \left (3\,c+3\,d\,x\right )}{4}+\frac {B\,a^4\,\sin \left (c+d\,x\right )}{4}+\frac {B\,b^4\,\sin \left (c+d\,x\right )}{2}+A\,a^3\,b\,\sin \left (c+d\,x\right )+A\,a^3\,b\,\sin \left (3\,c+3\,d\,x\right )+2\,B\,a\,b^3\,\sin \left (2\,c+2\,d\,x\right )}{d\,\left (\frac {\cos \left (2\,c+2\,d\,x\right )}{2}+\frac {1}{2}\right )} \]
[In]
[Out]